<table id="settings">
    <tbody>
        {% set section = namespace(section='') %}
        {% for set in settings %}
        {% if page == "servers.py" and (set.section == 'monitoring' or set.section == 'rabbitmq') %}
        <!-- continue -->
        {% else %}
        {% if section.section|string() != set.section|string() %}
        <th colspan="3" title="Show {{ set.section }} section" id="{{set.section}}-section-head" style="cursor: pointer; padding-top: 10px;">
            <h3 class="plus-after" id="{{set.section}}-section-h3" style="font-size: 1em; padding-left: 15px;">
                {% if set.section == 'ldap' %}
                {{ set.section|upper}}
                {% else %}
                {{ set.section[0]|upper}}{{set.section[1:] }}
                {% endif %}
            </h3>
        </th>
        <tr class="overviewHead {{set.section}}-section" style="display: none">
            <td class="padding10 first-collumn">Parameter</td>
            <td class="addOption">Value</td>
            <td class="addOption">Description</td>
        </tr>
        {% endif %}
        {% set section.section = set.section %}
        <tr class="{{ loop.cycle('odd', 'even') }} {{set.section}}-section" style="display: none">
            <td class="addName">
                {{set.param}}
            </td>
            <td class="addOption">
                {% if set.param in ('ldap_password', 'stats_password', 'nginx_stats_password', 'apache_stats_password', 'rabbitmq_password') %}
                    {% if set.value is none %}
                        {{ input(set.param, size='25', type='password') }}
                    {% else %}
                        {{ input(set.param, size='25', type='password', placeholder='*****') }}
                    {% endif %}
                {% elif set.param in ('nginx_stats_port', 'session_ttl', 'token_ttl', 'stats_port', 'haproxy_sock_port',
                    'ldap_type', 'ldap_port', 'ldap_enable', 'log_time_storage', 'syslog_server_enable', 'smon_check_interval',
                    'checker_check_interval', 'port_scan_interval', 'smon_keep_history_range', 'checker_keep_history_range',
					'portscanner_keep_history_range', 'haproxy_enterprise', 'checker_maxconn_threshold', 'apache_stats_port') %}

                    {{ input(set.param, value=set.value, style='width: 210px;', type='number') }}
                {% else %}
                    {% if set.value is none %}
                        {{ input(set.param, size='25') }}
                    {% else %}
                        {{ input(set.param, value=set.value, size='25') }}
                    {% endif %}
                {% endif %}
            </td>
            <td class="addOption">
                {{set.desc}}
            </td>
        </tr>
        {% endif %}
        {% endfor %}
    </tbody>
</table>
